﻿using System.ComponentModel;
using System.ComponentModel.DataAnnotations;
using System.Text.Json.Serialization;
namespace BPM.Web.Shared.Data;

/// <summary>
/// 上传文件参数
/// </summary>
public partial class FileOutput : BaseVM
{
    /// <summary>
    /// 主键Id
    /// </summary>
    [DisplayName("业务号")]
    [Required(ErrorMessage = "业务号不能为空")]
    [JsonPropertyName("id")]
    public long Id { get; set; }

    /// <summary>
    /// 文件存储位置（1:阿里云，2:腾讯云，3:minio，4:本地）
    /// </summary>
    [DisplayName("存储位置")]
    [JsonPropertyName("fileLocation")]
    public FileLocation FileLocation { get; set; }

    /// <summary>
    /// 文件仓库
    /// </summary>
    [DisplayName("仓库")]
    [JsonPropertyName("fileBucket")]
    public string? FileBucket { get; set; }

    /// <summary>
    /// 文件名称（上传时候的文件名）
    /// </summary>
    [DisplayName("上传名称")]
    [JsonPropertyName("fileOriginName")]
    public string? FileOriginName { get; set; }

    /// <summary>
    /// 文件后缀
    /// </summary>
    [DisplayName("后缀")]
    [JsonPropertyName("fileSuffix")]
    public string? FileSuffix { get; set; }

    /// <summary>
    /// 文件大小kb
    /// </summary>
    [DisplayName("大小kb")]
    [JsonPropertyName("fileSizeKb")]
    public long FileSizeKb { get; set; }

    /// <summary>
    /// 文件大小信息，计算后的
    /// </summary>
    [DisplayName("大小信息")]
    [JsonPropertyName("fileSizeInfo")]
    public string? FileSizeInfo { get; set; }

    /// <summary>
    /// 存储到bucket的名称（文件唯一标识id）
    /// </summary>
    [DisplayName("唯一标识id")]
    [JsonPropertyName("fileObjectName")]
    public string? FileObjectName { get; set; }

    /// <summary>
    /// 存储路径
    /// </summary>
    [DisplayName("存储路径")]
    [JsonPropertyName("filePath")]
    public string? FilePath { get; set; }

}
